What are basis functions and why do we need them?

Your browser does not support the video tag.

Comparing different Basis Functions

After this quick introduction, you can explore the use of different basis functions with the model provided below. In the different figures you can either compare different basis functions or play with the parameters of one basis functions to observe their influence on the graph. Have fun! This model allows you to compare different basis functions.

Polynomial Basis Functions

Now that you've seen how the basis functions differ in their curves, let's play around with their parameters a bit. First is the polynomial basis function. Polynomial basis functions are used for modelling simple relationships between predictors and targets. They depend on the degree of the polynomial, as a polynomial of a higher degree allows more basis functions. You can observe how the curve changes by changing the degree.

Periodical Basis Functions

Periodical basis functions are used for phenomena that happen periodically. For example: oscillations, clustering or time series analysis. Here you can observe how changing the frequency and number of basis functions influences the data fit.

Sigmoidal Basis Functions

Sigmoidal basis functions are also used for non-linear relationships in the data. An example of its field of use is in the learning of neuronal networks and the discovery of functions which suit well for the resolving in supervised learning. You can change the number of basis functions to see how the model changes.

Gaussian Basis Functions

Gaussian basis functions use the Gaussian probability density function as a basis function. Because they can model non-linear relationships very well they are for example used for supervised learning problems with non-linear relationships between predictor and target. They are local basis functions, which is useful because of its faster computation. Again, you can change the number of basis functions and observe the effects.

B-Splines

B-splines can be used to approximate splines over a set of points. They are also used to approximate nonlinear functions and non-periodic data. They can f.e. be used for computer aided geometry design programs. Here, we let you increase the number of knot and observe the changes of the curve.

Cubic Splines

Cubic splines are piecewise cubic functions presented as a smooth curve with a given set of points. So it is used for situations where smooth curves have to be modeled. It is an efficient method for data interpolation and is used by f.e. engineering for curve fitting. By choosing different coordinates for the knot, you can change how the model fits the data.

References:

Cai, E. (2014). Gaussian Basis Function Models [Blog post]. The Chemical Statistician. Retrieved from https://chemicalstatistician.wordpress.com/tag/gaussian-basis-function-models/. (Last accessed: January 30, 2023).

Saeed, M. (2021). A Gentle Introduction To Sigmoid Function [Blog post]. Machine Learning Mastery. Retrieved from https://machinelearningmastery.com/a-gentle-introduction-to-sigmoid-function/. (Last accessed: January 30, 2023)

Shene, C. (2011). B-spline Basis Functions. Michigan Technological University. Retrieved from https://pages.mtu.edu/~shene/COURSES/cs3621/NOTES/spline/B-spline/bspline-basis.html. (Last accessed: January 30, 2023).

Ramsay, J. O., & Silverman, B. W. (n.d.). Example: B-Spline Basis. McGill University. Retrieved from http://www.psych.mcgill.ca/misc/fda/ex-basis-a1.html. (Last accessed: January 30, 2023).

Wittmers, A., & Gensel, M. (2006). Modellierung von Kurven und Flächen mittels B-Splines [PDF document]. Freie Universität Berlin. Retrieved from http://www.inf.fu-berlin.de/lehre/SS06/Computergraphik/skript/vorlesung4.pdf (Last accessed: February 1, 2023).

McClarren, R. G. (2018). Computational Nuclear Engineering and Radiological Science Using Python (Chapter 10). Academic Press. Retrieved from https://www.sciencedirect.com/science/article/pii/B9780128122532000121 (Last accessed: February 1, 2023).

Korol, R. M. (2014). Cubic spline interpolation for petroleum engineering data. ResearchGate. Retrieved from https://www.researchgate.net/publication/287245396_Cubic_spline_interpolation_for_petroleum_engineering_da (Last accessed: February 1, 2023).

images: all images in the presentation were generated using our model

dataset: Pipa, G. (2022). Course: Neuroinformatics Content, Coding Assignments